package com.example.bes952.dcs2.demo2.controller;

import com.bes.dcs.api.config.annotation.DcsValue;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class TestController {
    private static final Logger log = LoggerFactory.getLogger(TestController.class);

    @Value(value = "${hello:hello}")
    private String hello;

    @GetMapping(value = "/")
    public String index() {
        return "welcome to use bes dcs";
    }

    @GetMapping(value = "/dcs/value")
    public String dcsConfigTest() {
        return hello;
    }
}
